package com.xxx.article.repository;

import com.xxx.article.domain.Comment;
import org.springframework.data.mongodb.repository.MongoRepository;

import java.util.List;

/**
 * @author blijojo
 * @date 2021/6/14
 */
public interface CommentRepository extends MongoRepository<Comment, String> {

    /**
     * 根据文章id查询评论
     *
     * @param articleId 文章id
     * @return List<Comment>
     */
    List<Comment> findByArticleId(String articleId);

}
